From 23673e97a9420f7f253622ca4a7f9b7d2e610f08 Mon Sep 17 00:00:00 2001 From: oliskoli Date: Thu, 13 Oct 2005 21:52:42 +0000 Subject: [PATCH] Fix waypt counter in waypt_backup --- gpsbabel/waypt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gpsbabel/waypt.c b/gpsbabel/waypt.c index 0fdbc2b02..c01defd1c 100644 --- a/gpsbabel/waypt.c +++ b/gpsbabel/waypt.c @@ -320,8 +320,7 @@ waypt_backup(unsigned int *count, queue **head_bak) { queue *elem, *tmp, *qbackup; waypoint *wpt; - // BUG(akirmse): no was not initialized. Set to 0 for now to compile it. - int no = 0; + int no = 0; qbackup = (queue *) xcalloc(1, sizeof(*qbackup)); QUEUE_INIT(qbackup); @@ -335,6 +334,7 @@ waypt_backup(unsigned int *count, queue **head_bak) { wpt = (waypoint *)elem; waypt_add(waypt_dupe(wpt)); + no++; } *head_bak = qbackup; -- 2.30.2